package com.zxyankh.raft.thread;

import com.zxyankh.raft.context.ApplicationContextUtil;
import com.zxyankh.raft.service.RaftService;

/**
 * @author ankh
 * @since 09.12.2017
 */
public class RpcServerThread extends Thread {

    private RaftService raftService;

    public RpcServerThread(RaftService raftService) {
        this.raftService = raftService;
    }

    @Override
    public void run() {
        raftService = ApplicationContextUtil.getApplicationContext().getBean(RaftService.class);
    }
}
